import request from '@/utils/request'

export function getWordsTree(query) {
  return request({
    url: '/wordFream/list',
    method: 'get',
    params: query
  })
}
export function addTreeNodes(query) {
  return request({
    url: '/wordFream/addOrUpdate',
    method: 'post',
    data: query
  })
}
export function deleteTreeNodes(query) {
  return request({
    url: '/wordFream/delete',
    method: 'get',
    params: query
  })
}

// 统计各节点上, 关键词在一篇政策中出现的个数(一个关键词算1个)
// @param id 政策id
export function countWordsInPolicy(query) {
  return request({
    url: '/policy/wordKeyword',
    method: 'get',
    params: query
  })
}



